<script>
    function click(a) {
        var i;
        for (i = 0; i < document.getElementsByClassName("divs").length; i++) {
            if (i !== a) document.getElementsByClassName("divs").item(i).style.display="none";
            else document.getElementsByClassName("divs").item(i).style.display="block";
        };
    }
</script>

<html>
    <head>
        <title>TODO supply a title</title>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width">
        <link rel="stylesheet" href="css/index.css">
    </head>
    
    <body>
        <div class="pure-menu pure-menu-open pure-menu-horizontal">
            <a href="#" class="pure-menu-heading">CONSULTORIO</a>

            <ul>
                <li class="pure-menu-selected"><a href="#">Home</a></li>
                <li><a href=javascript:click(0)>Consultar Paciente</a></li>
                <li><a href=javascript:click(1)>Consultar Exame</a></li>
                <li><a href=javascript:click(2)>Consultar Horario</a></li>
            </ul>
        </div>
        
        
    </body>
</html>
